// 对数组类型定义的两种方式
let arrNum:Array<number> = [1,2,3]
let arrStr:string[] = ['well', 'liu', 'guowei']

// 定义联合类型数组
let arr:(number | string | {})[]
arr = [1, 'well', {}]

// 定义指定对象成员的数组
interface arrObj {
    name: string,
    age: number
}

let arrObj:arrObj[] = [
    {
        name: 'well',
        age: 22
    }
]